package com.example.evaluate.model;

import com.alibaba.fastjson.JSON;
import lombok.*;

import java.util.ArrayList;

/**
 * 学生类
 * 记录学生基本信息
 * */
@Setter
@Getter
@EqualsAndHashCode
@NoArgsConstructor
@AllArgsConstructor
public class Student {
    private Integer studentId;//学号
    private String studentName;//学生名字
    private String studentPassword;//学生密码
    private String studentAcademy;//学生学院
    private String studentMajor; //学生专业
    private String studentClass; //学生班级

    public Student(Integer studentId, String studentName, String studentPassword) {
        this.studentId = studentId;
        this.studentName = studentName;
        this.studentPassword = studentPassword;
    }

    private ArrayList<Teacher> teachers;//一个学生对应一个老师列表

    @Override
    public String toString() {
        return JSON.toJSONString(this);
    }

    public Student(Integer studentId, String studentPassword) {
        this.studentId = studentId;
        this.studentPassword = studentPassword;
    }

    public Student(Integer studentId) {
        this.studentId = studentId;
    }
}
